package com.future.account.client;

import com.future.account.client.hystrix.EmailInfoFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 邮件信息接口Feign客户端
 *
 * @author shiyong
 * 2021/7/27 8:10
 */
@FeignClient(qualifier = "emailInfoClient", name = "emailService", path = "/email/emailInfo",
        fallback = EmailInfoFallback.class)
public interface EmailInfoClient {
    /**
     * 发送邮件
     *
     * @param email 邮件地址
     * @return java.lang.String
     * @author shiyong
     * 2021/7/27 8:16
    */
    @PostMapping("/sendEmail")
    String sendEmail(@RequestParam String email);
}
